<template>
  <div>
    <Row type="flex" justify="center">
      <Col span="24">
        <Table border :loading="tableLoading" :columns="tableColumns" :data="tableData"></Table>
      </Col>
    </Row>
    <br>
    <Row type="flex" justify="end">
      <Page show-total :current="pageObj.pageNo" :page-size="pageObj.pageSize" :total="pageObj.totalRecord" @on-change="getPageNo"/>
    </Row>
  </div>
</template>

<script>
import {} from '@/api/yi-qing-fang-kong'
// import mockData from './mockData'

export default {
  name: 'area-warning',
  data () {
    return {
      tableColumns: [
        {
          title: '序号',
          type: 'index',
          width: 70,
          // fixed: 'left',
          align: 'center'
        },
        {
          title: '区县',
          key: 'district',
          width: 200,
          align: 'center'
        },
        {
          title: '街道',
          key: 'street',
          width: 250,
          align: 'center'
        },
        {
          title: '社区',
          width: 250,
          key: 'community',
          align: 'center'
        },
        {
          title: '死亡人数',
          width: 200,
          key: 'die',
          align: 'center'
        },
        {
          title: '治愈人数',
          width: 200,
          key: 'die',
          align: 'center'
        },
        {
          title: '疑似人数',
          minWidth: 200,
          key: 'suspected',
          align: 'center'
        }
      ],
      tableData: [],
      tableLoading: false,
      pageObj: {
        pageNo: 1,
        pageSize: 10,
        totalRecord: 0
      }
    }
  },
  props: {},
  mounted () {
    // this.tableData = mockData.data.data
    // this.pageObj.totalRecord = this.tableData.length
    this.init()
  },
  methods: {
    getPageNo () {},
    init () {
      // xx().then(ret => {
      //   if (ret.data.errcode === 0) {
      //     this.tableData = ret.data.data
      //   } else {
      //     this.$Message.error({
      //       content: '数据获取失败,\n' + ret.data.errmsg
      //     })
      //   }
      // })
    }
  }
}
</script>

<style scoped>
</style>
